package com.edu.juc.introduction.communication.custom;

public class PrintStringTest {
    public static void main(String[] args) {
        PrintString printString = new PrintString();
        new Thread(() -> {
            for (int i = 0; i < 3; i++) {
                printString.print1();
            }
        }, "AA").start();

        new Thread(() -> {
            for (int i = 0; i < 3; i++) {
                printString.print2();
            }
        }, "BB").start();

        new Thread(() -> {
            for (int i = 0; i < 3; i++) {
                printString.print3();
            }
        }, "CC").start();
    }
}
